class Rectangle:
    def __init__(self, width=0, height=0):
        self.width = width
        self.height = height

    def __setattr__(self, name, value):
        if name == "square":
            self.width = value
            self.height = value
        else:
            super().__setattr__(name, value)

    def get_area(self):
        return self.width * self.height


if __name__ == "__main__":
    r1 = Rectangle(4, 5)
    area = r1.get_area()
    print(area)
    r1.square = 10
    print(r1.get_area())